<template>
    <div id="app">
        <router-view></router-view>
        <AboutUs></AboutUs>
        <!--<Pop v-if="pop" @closePop="closePopFn"></Pop>-->
    </div>
</template>
<script>
    import AboutUs from "./components/AboutUs.vue"
    import Pop from "./components/Pop"
    import store from './store/store'
    export default {
        name: 'App',
        components: {
            AboutUs,
            Pop
        },
        data(){
          return{
              pop:true
          }
        },
        methods:{
            closePopFn(val){
               this.pop= val;
            }
        },
        mounted(){
            if(!store.state.token){
                this.pop=true;
            }
            var m = navigator.userAgent;
            var isIos = !!m.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/);
            if (isIos) {
                let inputs = document.querySelectorAll('input');
                inputs.forEach(function(input){
                    input.addEventListener('blur',function(){
                        setTimeout(() => {
                            window.scrollTo(0, input.offsetTop); 
                        }, 0);
                    },false)　
                })
                let textareas = document.querySelectorAll('textarea');
                textareas.forEach(function(textare){
                    textare.addEventListener('blur',function(){
                        setTimeout(() => {
                            window.scrollTo(0, textare.offsetTop); 
                        }, 0);
                    },false)　
                })
            }
        }
    }
</script>
<style lang="scss">
    *{padding: 0;margin: 0}
    article, aside, details, figcaption, figure, footer, header, hgroup, menu, nav, section {display: block;}
    ul, ul li, ol li, li {	list-style:none;}
    table {	border-collapse: collapse;	border-spacing: 0;}
    input, textarea {border: 0;	outline: none;  -webkit-appearance: none; /*去掉内部阴影*/}
    input[type=input]{-webkit-appearance:none;} /*移除ios样式*/
    input[type=checkbox]{-webkit-appearance:checkbox;}
    /*去除a标签的虚线框*/
    a {outline: none; text-decoration:none; -webkit-tap-highlight-color: rgba(0,0,0,0); -webkit-tap-highlight-color:transparent;}
    html,body {width:100%; height:100%; -webkit-text-size-adjust: 100%; /*禁止文本缩放*/ margin: 0; padding: 0;}

    div,button,checkbox-group,checkbox,form,input,label {
        box-sizing: border-box;
    }
    img{vertical-align:middle}
    .mint-toast,.mint-actionsheet,.mint-indicator-wrapper,.mint-indicator-mask{
        z-index: 100006 !important;
    }
    .mint-msgbox-wrapper{
        z-index: 100005 !important;
    }
    .mint-msgbox-wrapper + .v-modal{
        z-index: 100004 !important;
    }
    .mint-msgbox-cancel,.mint-msgbox-confirm{
        font-size: 15px;
    }
    @import  "./assets/base.scss";
    @import  "./assets/icon/iconfont.css";
    #app {
        font-family: "Avenir", Helvetica, Arial, sans-serif;
        color: #000;
        width: 100%;
        height: 100%;
        line-height: 1;
        font-size: 0.4rem
    }
    a{color:#000;text-decoration: none}
    .header{
        &-btnLeft{
            padding: rpx(8) 0!important;
            display: flex;
            align-items: center;
        }
    }
</style>
